package kr.co.cherryt.activity;

import kr.co.cherryt.cherryt.R;
import android.app.Activity;
import android.os.Bundle;
import android.os.Handler;
import android.util.Log;
import android.view.WindowManager;

public class IntroActivity extends Activity {

	Handler handler = new Handler();

	Runnable fisishRunnable = new Runnable() {
		public void run() {
			finish();
		}
	};

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.intro_activity);
		
		getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
											WindowManager.LayoutParams.FLAG_FULLSCREEN);

		handler.postDelayed(fisishRunnable, 2000);	// 종료 작업 예약
		//Log.d("lifecycle", "intro 1. onCreate" );
	}

	@Override
	protected void onDestroy() {
		handler.removeCallbacks(fisishRunnable);	// 대기열의 작업 취소 (작업 실행 전)
		super.onDestroy();
	}
}
